# include <cstdio>
# include <cstring>
# include <iostream>
# include <algorithm>
# include <cmath>
using namespace std;

# define testin freopen("in.txt", "r", stdin)
# define testout freopen("out.txt", "w", stdout)

# define rep(x) for(int i = 0; i < (x); ++i)
# define clr(x) memset(x, 0, sizeof(x))
# define clr(x, c) memset(x, 0, (c)*sizeof(x[0]))

typedef unsigned long long int ulli;
typedef long long int lli;


double a, b, c, d, L, R;
void cal(double x, double &ans)
{
    double t = fabs( a*x*x*x + b*x*x + c*x + d );
    ans = ans > t  ? ans:t;
}

int main()
{
    double ans;
    while (cin >> a >> b >> c >> d >> L >> R) {
        ans = 0;
        cal(L, ans); cal(R, ans);
        if (4*b*b >= 12*a*c) {
            double delta = sqrt(4*b*b-12*a*c);
            double x1 = (-2*b+delta)/(6*a);
            double x2 = (-2*b-delta)/(6*a);
            cal(x1, ans); cal(x2, ans);
        }
        printf("%.2f\n", ans);
    }

    return 0;
}
